//
//  XLDiscoverTopView.swift
//  SinaWeibo
//
//  Created by 李凯 on 16/8/31.
//  Copyright © 2016年 kevin. All rights reserved.
//

import UIKit

 class XLDiscoverTopView: UIButton {

    //提供一个类方法 创建view
    class func topView() ->XLDiscoverTopView {
        let topView = Bundle.main.loadNibNamed("XLDiscoverTopView", owner: nil, options: nil)!.last as!XLDiscoverTopView
        return topView
    }
    
    override func awakeFromNib() {
        self.imageEdgeInsets = UIEdgeInsetsMake(0, 10, 0, -10)
        self.titleEdgeInsets = UIEdgeInsetsMake(0, 20, 0, -20)
        
        //设置圆角
       // layer.cornerRadius = 10
       // layer.masksToBounds = true
    }

}
